export default {
  // state为公用的数据，city为传进来的数据
  changeCity (state, city) {
  // 将公用数据里的城市名更改为传进来的城市名
    state.city = city
    try {
      localStorage.city = city
    } catch (e) {}
  },

  changeScenicSpot (state, scenicSpot) {
    // 将公用数据里的景点名更改为传进来的景名
    state.scenicSpot = scenicSpot
    try {
      localStorage.scenicSpot = scenicSpot
    } catch (e) {}
  }
}
